import {
  Column,
  Entity,
  PrimaryGeneratedColumn,
} from 'typeorm';
@Entity('posts')
export class Posts {
  // 主键，并自增
  @PrimaryGeneratedColumn()
  id: number;

  @Column()
  title: string;

  @Column()
  content: string;

  @Column()
  author: string;
}
